package base.Day03;

public class IfElseDemo
{
    public static void main(String[] args)
    {
        IfElseDemo ifElseDemo = new IfElseDemo();
        ifElseDemo.test();
    }

    void test()
    {
          double price = 10001;
          if(price > 1000)
          {
              price *= 0.6;
          }else {
              price *= 0.9;
          }
        System.out.println("price = "+ price);
          String s1 = String.format("%.1f",price);
        System.out.println(s1);
    }


}
